﻿@model PotentialAdviceViewModel
@{
    Layout = null;
    ViewBag.Title = "隐患整改通知书台账-编辑";
}
<script src="/Scripts/jQuery/jquery.validate.min.js" type="text/javascript"></script>
<script src="/Scripts/jQuery/jquery.validate.unobtrusive.min.js" type="text/javascript"></script>
<script type="text/javascript">
    function dialogRefresh(json) {
        DWZ.ajaxDone(json);
        if (json.statusCode == DWZ.statusCode.ok) {
            $("#pagerForm", navTab.getCurrentPanel()).submit();
            $.pdialog.closeCurrent();
        }
    }
</script>
@{Html.EnableClientValidation();}
@using (Html.BeginForm("PotentialAdviceEditData", "ScmPotentialAdvice", null, FormMethod.Post, new { onsubmit = "return validateCallback(this,dialogRefresh);", @class = "pageForm required-validate" }))
{
@*<form method="post" action="@Url.Action("PotentialAdviceEditData", "ScmPotentialAdvice")" class="pageForm required-validate" onsubmit="return validateCallback(this,dialogAjaxDone)">*@
<div class="pageFormContent sortDrag" layouth="60">
    @Html.TextBoxFor(model => model.PotentialAdviceInfo.Pa_ID, new { @type = "hidden" })
    <table class="tab01 tabNo" width="100%;">
        <tr>
            <td class="td1" style="width:30%;">
                施工单位：
            </td>
            <td>
                @Html.TextBoxFor(m => m.PotentialAdviceInfo.Pa_UnitID, new { @type = "hidden" })
                @Html.TextBoxFor(m => m.PotentialAdviceInfo.Pa_UnitName, new { @class = "required input02", @readonly = "readonly", @size = "27" })
                <a class="btnLook" href="@Url.Action("UnitList", "ProjectSegment", new { uId = "PotentialAdviceInfo_Pa_UnitID", uName = "PotentialAdviceInfo_Pa_UnitName", uSection = "PotentialAdviceInfo_Pa_Section" })" lookupgroup="PotentialAdviceInfo" title="选择施工单位">
                    查找带回</a>
            </td>
        </tr>
        <tr>
            <td class="td1">
                合同段：
            </td>
            <td>
                  @Html.TextBoxFor(model => model.PotentialAdviceInfo.Pa_Section, new Dictionary<string, object> { { "class", "data-val-required input02" }})
                  @Html.ValidationMessageFor(model => model.PotentialAdviceInfo.Pa_Section)
               @* @Html.TextBoxFor(model => model.PotentialAdviceInfo.Pa_Section, new { @class = "input02" })*@
            </td>
        </tr>
        <tr>
            <td class="td1">
                日期：
            </td>
            <td>
                @Html.TextBoxFor(model => model.PotentialAdviceInfo.Pa_Date, new { @class = "date input02", Value = (Model.PotentialAdviceInfo.Pa_Date == null ? "" : Convert.ToDateTime(Model.PotentialAdviceInfo.Pa_Date).ToString("yyyy-MM-dd")) })
            </td>
        </tr>
        <tr>
            <td class="td1">
                编号：
            </td>
            <td>
                @Html.TextBoxFor(model => model.PotentialAdviceInfo.Pa_Number, new { @class = "input02" })
            </td>
        </tr>
        <tr>
            <td class="td1">
                检查地点：
            </td>
            <td>
                @Html.TextBoxFor(model => model.PotentialAdviceInfo.Pa_Location, new { @class = "input02" })
            </td>
        </tr>
        <tr>
            <td class="td1">
                监理是否回复：
            </td>
            <td>
                @Html.DropDownListFor(model => model.PotentialAdviceInfo.Pa_IsCheck, ViewBag.list as IEnumerable<SelectListItem>)
            </td>
        </tr>
        <tr>
            <td class="td1">
                回复日期：
            </td>
            <td>
                @Html.TextBoxFor(model => model.PotentialAdviceInfo.Pa_ReplyDate, new { @class = "date input02", Value = (Model.PotentialAdviceInfo.Pa_ReplyDate == null ? "" : Convert.ToDateTime(Model.PotentialAdviceInfo.Pa_ReplyDate).ToString("yyyy-MM-dd")) })
            </td>
        </tr>
        <tr>
            <td class="td1">
                安全隐患：
            </td>
            <td>
                @* @Html.TextBoxFor(model => model.PotentialAdviceInfo.Pa_Problem, new { @size = "95" })*@
                @Html.TextAreaFor(model => model.PotentialAdviceInfo.Pa_Problem, new { cols = "80", rows = "5", @class = "input05" })
            </td>
        </tr>
        <tr>
            <td class="td1">
                整改情况：
            </td>
            <td>
                @* @Html.TextBoxFor(model => model.PotentialAdviceInfo.Pa_Correct, new { @size = "95" })*@
                @Html.TextAreaFor(model => model.PotentialAdviceInfo.Pa_Correct, new { cols = "80", @class = "input05" })
            </td>
        </tr>
        <tr>
            <td class="td1">
                备注：
            </td>
            <td>
                @Html.TextBoxFor(model => model.PotentialAdviceInfo.Pa_Remark, new { @size = "95", @class = "input05" })
            </td>
        </tr>
    </table>
</div>
<div class="formBar">
    <ul>
        <li>
            <button type="submit" class="btn btn-sm">
                保存</button>
        </li>
        <li>
            <button type="button" class="close btn btn-default btn-sm">
                取消</button>
        </li>
    </ul>
</div>
@*</form>*@
}
